package com.cmc.cloud.cmclink.doc.vo.special.dgextconfigvo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * 特种货DG关联配置 Base VO，提供给添加、修改、详细的子 VO 使用
 * 如果子 VO 存在差异的字段，请不要添加到这里，影响 Swagger 文档生成
 *
 * @author codegen
 */
@Data
public class SpecialCargoDgConfBaseVO {

    @Schema(description = "主键ID")
    private Long id;

    @Schema(description = "参考来源字段", requiredMode = Schema.RequiredMode.REQUIRED, example = "芋艿")
    @NotBlank(message = "{specialcargodgconf.dgrefername.notblank}")
    @Length(max = 50, message = "{specialcargodgconf.dgrefername.length}")
    private String dgReferName;

    @Schema(description = "参考来源字段对应值", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotBlank(message = "{specialcargodgconf.dgrefervalue.notblank}")
    @Length(max = 50, message = "{specialcargodgconf.dgrefervalue.length}")
    private String dgReferValue;

    @Schema(description = "扩展字段名", requiredMode = Schema.RequiredMode.REQUIRED, example = "李四")
    @NotBlank(message = "{specialcargodgconf.dgextname.notblank}")
    @Length(max = 50, message = "{specialcargodgconf.dgextname.length}")
    private String dgExtName;

    @Schema(description = "扩展字段对应值", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotBlank(message = "{specialcargodgconf.dgextvalue.notblank}")
    @Length(max = 50, message = "{specialcargodgconf.dgextvalue.length}")
    private String dgExtValue;

    @Schema(description = "扩展字段对应值单位", requiredMode = Schema.RequiredMode.REQUIRED)
    @Length(max = 50, message = "{specialcargodgconf.dgextvalueunit.length}")
    private String dgExtValueUnit;

    @Schema(description = "启用标识", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "{specialcargodgconf.enable.notnull}")
    private Boolean enable;

    @Schema(description = "备注", example = "你猜")
    @Length(max = 200, message = "{specialcargodgconf.remark.length}")
    private String remark;

    @Schema(description = "比较运算逻辑")
    @Length(max = 10, message = "{specialcargodgconf.comparativeLogic.length}")
    @NotNull(message = "{specialcargodgconf.comparativeLogic.notnull}")
    private String comparativeLogic;

}
